Optimal. Leaf size=139 \[ \frac{1}{2} \sqrt{\sqrt{10}-\frac{13}{5}} \tan ^{-1}\left (\frac{\left (1+4 \sqrt{10}\right ) x+3 \left (4-\sqrt{10}\right )}{2 \sqrt{1+\sqrt{10}} \sqrt{-2 x^2+3 x+1}}\right )+\frac{1}{2} \sqrt{\frac{13}{5}+\sqrt{10}} \tanh ^{-1}\left (\frac{\left (1-4 \sqrt{10}\right ) x+3 \left (4+\sqrt{10}\right )}{2 \sqrt{\sqrt{10}-1} \sqrt{-2 x^2+3 x+1}}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.220049, antiderivative size = 139, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 4, integrand size = 30, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.133, Rules used = {1032, 724, 204, 206} \[ \frac{1}{2} \sqrt{\sqrt{10}-\frac{13}{5}} \tan ^{-1}\left (\frac{\left (1+4 \sqrt{10}\right ) x+3 \left (4-\sqrt{10}\right )}{2 \sqrt{1+\sqrt{10}} \sqrt{-2 x^2+3 x+1}}\right )+\frac{1}{2} \sqrt{\frac{13}{5}+\sqrt{10}} \tanh ^{-1}\left (\frac{\left (1-4 \sqrt{10}\right ) x+3 \left (4+\sqrt{10}\right )}{2 \sqrt{\sqrt{10}-1} \sqrt{-2 x^2+3 x+1}}\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 1032
Rule 724
Rule 204
Rule 206
Rubi steps
\begin{align*} \int \frac{2+x}{\left (2+4 x-3 x^2\right ) \sqrt{1+3 x-2 x^2}} \, dx &=\frac{1}{5} \left (5-4 \sqrt{10}\right ) \int \frac{1}{\left (4-2 \sqrt{10}-6 x\right ) \sqrt{1+3 x-2 x^2}} \, dx+\frac{1}{5} \left (5+4 \sqrt{10}\right ) \int \frac{1}{\left (4+2 \sqrt{10}-6 x\right ) \sqrt{1+3 x-2 x^2}} \, dx\\ &=-\left (\frac{1}{5} \left (2 \left (5-4 \sqrt{10}\right )\right ) \operatorname{Subst}\left (\int \frac{1}{144+72 \left (4-2 \sqrt{10}\right )-8 \left (4-2 \sqrt{10}\right )^2-x^2} \, dx,x,\frac{-12-3 \left (4-2 \sqrt{10}\right )-\left (18-4 \left (4-2 \sqrt{10}\right )\right ) x}{\sqrt{1+3 x-2 x^2}}\right )\right )-\frac{1}{5} \left (2 \left (5+4 \sqrt{10}\right )\right ) \operatorname{Subst}\left (\int \frac{1}{144+72 \left (4+2 \sqrt{10}\right )-8 \left (4+2 \sqrt{10}\right )^2-x^2} \, dx,x,\frac{-12-3 \left (4+2 \sqrt{10}\right )-\left (18-4 \left (4+2 \sqrt{10}\right )\right ) x}{\sqrt{1+3 x-2 x^2}}\right )\\ &=\frac{1}{10} \sqrt{-65+25 \sqrt{10}} \tan ^{-1}\left (\frac{3 \left (4-\sqrt{10}\right )+\left (1+4 \sqrt{10}\right ) x}{2 \sqrt{1+\sqrt{10}} \sqrt{1+3 x-2 x^2}}\right )+\frac{1}{10} \sqrt{65+25 \sqrt{10}} \tanh ^{-1}\left (\frac{3 \left (4+\sqrt{10}\right )+\left (1-4 \sqrt{10}\right ) x}{2 \sqrt{-1+\sqrt{10}} \sqrt{1+3 x-2 x^2}}\right )\\ \end{align*}
Mathematica [A] time = 0.295987, size = 140, normalized size = 1.01 \[ \frac{\left (4 \sqrt{10}-5\right ) \tan ^{-1}\left (\frac{4 \sqrt{10} x+x-3 \sqrt{10}+12}{2 \sqrt{1+\sqrt{10}} \sqrt{-2 x^2+3 x+1}}\right )+3 \sqrt{5 \left (7+2 \sqrt{10}\right )} \tanh ^{-1}\left (\frac{-4 \sqrt{10} x+x+3 \left (4+\sqrt{10}\right )}{2 \sqrt{\sqrt{10}-1} \sqrt{-2 x^2+3 x+1}}\right )}{10 \sqrt{1+\sqrt{10}}} \]
Warning: Unable to verify antiderivative.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.135, size = 324, normalized size = 2.3 \begin{align*}{\frac{2\,\sqrt{10}}{5\,\sqrt{-1+\sqrt{10}}}{\it Artanh} \left ({\frac{9}{2\,\sqrt{-1+\sqrt{10}}} \left ( -{\frac{2}{9}}+{\frac{2\,\sqrt{10}}{9}}+ \left ({\frac{1}{3}}-{\frac{4\,\sqrt{10}}{3}} \right ) \left ( x-{\frac{2}{3}}-{\frac{\sqrt{10}}{3}} \right ) \right ){\frac{1}{\sqrt{-18\, \left ( x-2/3-1/3\,\sqrt{10} \right ) ^{2}+9\, \left ( 1/3-4/3\,\sqrt{10} \right ) \left ( x-2/3-1/3\,\sqrt{10} \right ) -1+\sqrt{10}}}}} \right ) }+{\frac{1}{2\,\sqrt{-1+\sqrt{10}}}{\it Artanh} \left ({\frac{9}{2\,\sqrt{-1+\sqrt{10}}} \left ( -{\frac{2}{9}}+{\frac{2\,\sqrt{10}}{9}}+ \left ({\frac{1}{3}}-{\frac{4\,\sqrt{10}}{3}} \right ) \left ( x-{\frac{2}{3}}-{\frac{\sqrt{10}}{3}} \right ) \right ){\frac{1}{\sqrt{-18\, \left ( x-2/3-1/3\,\sqrt{10} \right ) ^{2}+9\, \left ( 1/3-4/3\,\sqrt{10} \right ) \left ( x-2/3-1/3\,\sqrt{10} \right ) -1+\sqrt{10}}}}} \right ) }+{\frac{2\,\sqrt{10}}{5\,\sqrt{1+\sqrt{10}}}\arctan \left ({\frac{9}{2\,\sqrt{1+\sqrt{10}}} \left ( -{\frac{2}{9}}-{\frac{2\,\sqrt{10}}{9}}+ \left ({\frac{1}{3}}+{\frac{4\,\sqrt{10}}{3}} \right ) \left ( x-{\frac{2}{3}}+{\frac{\sqrt{10}}{3}} \right ) \right ){\frac{1}{\sqrt{-18\, \left ( x-2/3+1/3\,\sqrt{10} \right ) ^{2}+9\, \left ( 1/3+4/3\,\sqrt{10} \right ) \left ( x-2/3+1/3\,\sqrt{10} \right ) -1-\sqrt{10}}}}} \right ) }-{\frac{1}{2\,\sqrt{1+\sqrt{10}}}\arctan \left ({\frac{9}{2\,\sqrt{1+\sqrt{10}}} \left ( -{\frac{2}{9}}-{\frac{2\,\sqrt{10}}{9}}+ \left ({\frac{1}{3}}+{\frac{4\,\sqrt{10}}{3}} \right ) \left ( x-{\frac{2}{3}}+{\frac{\sqrt{10}}{3}} \right ) \right ){\frac{1}{\sqrt{-18\, \left ( x-2/3+1/3\,\sqrt{10} \right ) ^{2}+9\, \left ( 1/3+4/3\,\sqrt{10} \right ) \left ( x-2/3+1/3\,\sqrt{10} \right ) -1-\sqrt{10}}}}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] time = 1.56001, size = 487, normalized size = 3.5 \begin{align*} -\frac{1}{20} \, \sqrt{10}{\left (\frac{\sqrt{10} \arcsin \left (\frac{8 \, \sqrt{17} \sqrt{10} x}{17 \,{\left | 6 \, x + 2 \, \sqrt{10} - 4 \right |}} + \frac{2 \, \sqrt{17} x}{17 \,{\left | 6 \, x + 2 \, \sqrt{10} - 4 \right |}} - \frac{6 \, \sqrt{17} \sqrt{10}}{17 \,{\left | 6 \, x + 2 \, \sqrt{10} - 4 \right |}} + \frac{24 \, \sqrt{17}}{17 \,{\left | 6 \, x + 2 \, \sqrt{10} - 4 \right |}}\right )}{\sqrt{\sqrt{10} + 1}} - \frac{\sqrt{10} \log \left (-\frac{2}{9} \, \sqrt{10} + \frac{2 \, \sqrt{-2 \, x^{2} + 3 \, x + 1} \sqrt{\sqrt{10} - 1}}{3 \,{\left | 6 \, x - 2 \, \sqrt{10} - 4 \right |}} + \frac{2 \, \sqrt{10}}{9 \,{\left | 6 \, x - 2 \, \sqrt{10} - 4 \right |}} - \frac{2}{9 \,{\left | 6 \, x - 2 \, \sqrt{10} - 4 \right |}} + \frac{1}{18}\right )}{\sqrt{\sqrt{10} - 1}} - \frac{8 \, \arcsin \left (\frac{8 \, \sqrt{17} \sqrt{10} x}{17 \,{\left | 6 \, x + 2 \, \sqrt{10} - 4 \right |}} + \frac{2 \, \sqrt{17} x}{17 \,{\left | 6 \, x + 2 \, \sqrt{10} - 4 \right |}} - \frac{6 \, \sqrt{17} \sqrt{10}}{17 \,{\left | 6 \, x + 2 \, \sqrt{10} - 4 \right |}} + \frac{24 \, \sqrt{17}}{17 \,{\left | 6 \, x + 2 \, \sqrt{10} - 4 \right |}}\right )}{\sqrt{\sqrt{10} + 1}} - \frac{8 \, \log \left (-\frac{2}{9} \, \sqrt{10} + \frac{2 \, \sqrt{-2 \, x^{2} + 3 \, x + 1} \sqrt{\sqrt{10} - 1}}{3 \,{\left | 6 \, x - 2 \, \sqrt{10} - 4 \right |}} + \frac{2 \, \sqrt{10}}{9 \,{\left | 6 \, x - 2 \, \sqrt{10} - 4 \right |}} - \frac{2}{9 \,{\left | 6 \, x - 2 \, \sqrt{10} - 4 \right |}} + \frac{1}{18}\right )}{\sqrt{\sqrt{10} - 1}}\right )} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 1.64926, size = 948, normalized size = 6.82 \begin{align*} \frac{2}{5} \, \sqrt{5} \sqrt{5 \, \sqrt{5} \sqrt{2} - 13} \arctan \left (\frac{\sqrt{2}{\left (2 \, \sqrt{5} x - \sqrt{2} x\right )} \sqrt{5 \, \sqrt{5} \sqrt{2} - 13} \sqrt{\frac{\sqrt{5} \sqrt{2}{\left (3 \, x^{2} + 2 \, x\right )} + 6 \, x^{2} - 2 \,{\left (\sqrt{5} \sqrt{2} x + 2 \, x + 2\right )} \sqrt{-2 \, x^{2} + 3 \, x + 1} + 10 \, x + 4}{x^{2}}} + 2 \,{\left (\sqrt{2}{\left (4 \, x - 1\right )} + \sqrt{5}{\left (x + 2\right )} - \sqrt{-2 \, x^{2} + 3 \, x + 1}{\left (2 \, \sqrt{5} - \sqrt{2}\right )}\right )} \sqrt{5 \, \sqrt{5} \sqrt{2} - 13}}{18 \, x}\right ) - \frac{1}{10} \, \sqrt{5} \sqrt{5 \, \sqrt{5} \sqrt{2} + 13} \log \left (\frac{9 \, \sqrt{5} \sqrt{2} x +{\left (4 \, \sqrt{5} x - 7 \, \sqrt{2} x\right )} \sqrt{5 \, \sqrt{5} \sqrt{2} + 13} - 18 \, x + 18 \, \sqrt{-2 \, x^{2} + 3 \, x + 1} - 18}{x}\right ) + \frac{1}{10} \, \sqrt{5} \sqrt{5 \, \sqrt{5} \sqrt{2} + 13} \log \left (\frac{9 \, \sqrt{5} \sqrt{2} x -{\left (4 \, \sqrt{5} x - 7 \, \sqrt{2} x\right )} \sqrt{5 \, \sqrt{5} \sqrt{2} + 13} - 18 \, x + 18 \, \sqrt{-2 \, x^{2} + 3 \, x + 1} - 18}{x}\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} - \int \frac{x}{3 x^{2} \sqrt{- 2 x^{2} + 3 x + 1} - 4 x \sqrt{- 2 x^{2} + 3 x + 1} - 2 \sqrt{- 2 x^{2} + 3 x + 1}}\, dx - \int \frac{2}{3 x^{2} \sqrt{- 2 x^{2} + 3 x + 1} - 4 x \sqrt{- 2 x^{2} + 3 x + 1} - 2 \sqrt{- 2 x^{2} + 3 x + 1}}\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: TypeError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]